<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
    <head>
        <meta http-equiv="content-type" content="text/html; charset=UTF-8" />

        <title>会员列表</title>

        <link href="{$smarty.const.ADMIN_CSS_URL}mine.css" type="text/css" rel="stylesheet" />
    </head>
    <body>
        <style>
            {literal}
            .tr_color{background-color: #9F88FF}
            {/literal}
        </style>
        <div class="div_head">
			<span style="float: left;">当前位置是：会员管理-》会员列表</span>
        </div>
        <form class="search" action="{$smarty.const.__CONTROLLER__}/search" method="post">
	        <div style="margin-left:5px;">
	            <span><input name="key" placeholder="请输入会员账号" datatype="*" nullmsg="请输入关键词。" errormsg="输入有误。" type="text" /></span><span><input type="submit" value="查找"/></span>
	        </div>
        </form>
        <div style="font-size: 13px; margin: 10px 5px;">
            <table class="table_a" border="1" width="100%">
                <tbody><tr style="font-weight: bold;">
                        <td>序号</td>
                        <td>用户名</td>
                        <td>姓名</td>
                        <td>姓别</td>
                        <td>邮箱</td>
                        <td>QQ</td>
                        <td>手机</td>
                        <td>固话</td>
                        <td>地址</td>
                        <td>注册时间</td>
                        <td>最后登录时间</td>
                        <td>状态</td>
                        <td align="center">操作</td>
                    </tr>
                    {foreach $info as $k => $v}
                    <tr id="product1">
                        <td>{$v@iteration}</td>
                        <td>{$v.username}</td>
                        <td>{$v.name}</td>
                        {if $v.user_sex==0}
                        <td>男</td>
                        {else if $v.user_sex==1}
                        <td>女</td>
                        {/if}
                        <td>{$v.user_email}</td>
                        <td>{$v.user_qq}</td>
                        <td>{$v.phone}</td>
                        <td>{$v.telephone}</td>
                        <td>{$v.adress}</td>
                        <td>{date("Y-m-d H:i:s",$v.user_time)}</td>
                        <td>{date("Y-m-d H:i:s",$v.last_time)}</td>
                        
                        <td>
                        {if $v.status==0}
                        	未激活
                        {else if $v.status==1}
                        	正常
                        {else if $v.status==2}
                        	冻结
                        {else}
                        	异常
                        {/if}
                        	</td>
                        <td>
                        {if $v.status==1}
                        	<a href='{$smarty.const.__CONTROLLER__}/freeze/user_id/{$v.user_id}'>冻结</a>&nbsp;
                       	{else if $v.status==2}
                       		<a href='{$smarty.const.__CONTROLLER__}/unfreeze/user_id/{$v.user_id}'>解冻</a>&nbsp;
                       	{/if}
                            <a href='{$smarty.const.__CONTROLLER__}/upd/user_id/{$v.user_id}'>修改</a>
                            <a onclick="return confirm('确定删除？')" href='{$smarty.const.__CONTROLLER__}/del/user_id/{$v.user_id}'>删除</a></td>
                    </tr>
                    {/foreach}
                    <tr>
                        <td colspan="20" style="text-align: center;">
                        {$pagelist}
                        </td>
                    </tr>
                </tbody>
            </table>
        </div>
        
   	<script src="{$smarty.const.JS_URL}jquery-1.8.2.js"></script>
	<script type="text/javascript" src="{$smarty.const.VALIDFORM_JS_URL}Validform_v5.3.2.js"></script>
    <script type="text/javascript">
		$(function(){
			$(".search").Validform({
				tiptype:2
			});
		})
	</script>
        
    </body>
</html>